import { MsgLoadingClear } from '@C/Msg'
import type { IObj } from '@/interface'

export default (body: string, receiver?: string) => {
    const data: IObj = {}
    if (receiver) {
        data.phoneNumber = receiver
    }
    uni.sendSms({
        ...data,
        content: body,
        fail() { MsgLoadingClear({ msg: '调起短信接口失败' }) },
    })
}
